package cn.psvmc.cxzapi.response;

import lombok.Data;

import java.util.List;

@Data
public class PageResult<T> {

    // 数据列表
    private List<T> list;

    // 数据总数
    private long total;

    // 第几页
    private int page;

    // 每页条数
    private int size;

    public PageResult(){}

    public PageResult(List<T> list, long total){
        this.list = list;
        this.total = total;
    }

    public PageResult(List<T> list, long total, int page, int size){
        this.list = list;
        this.total = total;
        this.page = page;
        this.size = size;
    }
}
